#define DEBUG
#include <cstdio>
#define MAXFN 10000
#define MAXN 100
#define INF 0x7fffffff

using namespace std;

int main() {
#ifdef DEBUG
  freopen("1764.in", "r", stdin);
  freopen("1764.out", "w", stdout);
#endif

  static bool book[MAXN+1][MAXN+1];
  static long long f[MAXN+1][MAXN+1];
  int n, m, max, fn;
  scanf("%d %d %d %d", &n, &m, &max, &fn);
  for (int i=1; i<=m; i++) {
    int x, y;
    scanf("%d %d", &x, &y);
    book[n-x+1][y]=true;
  }
  f[1][1]=1;
  for (int i=2; i<=n; i++) {
    for (int j=1; j<=i; j++) {
      if (f[i-1][j-1]>=0 && f[i-1][j]>=0) {
	f[i][j] = (!book[i][j])*(f[i-1][j-1]+f[i-1][j]);
	f[i][j] = f[i][j]>INF ? -1 : f[i][j];
      }
    }
  }

  static bool dp[MAXN+2][MAXFN+1];
  static int g[MAXN+1][MAXFN+1];
  dp[n+1][fn]=true;
  for (int i=n; i>0; i--) {
    if (f[n][i]>0) {
      for (int j=0; j<=fn; j++) {
	for (int k=0; k<=max && (long long)j+k*f[n][i]<=fn; k++) {
	  if (dp[i+1][j+k*f[n][i]]) {
	    dp[i][j]=true;
	    g[i][j]=k;
	    break;
	  }
	}
      }
    } else {
      for (int j=0; j<=fn; j++) {
	dp[i][j]=dp[i+1][j];
	g[i][j]=0;
      }
    }
  }
  if (!dp[1][0]) {
    printf("-1\n");
    return 0;
  }
#ifdef DEBUG
  printf("BD:\n");
  for (int i=1; i<=n; i++) {
    printf("%lld\n", f[n][i]);
  }
  printf("ED\n");
#endif
  int x=0;
  for (int i=1; i<=n; i++) {
    printf("%d\n", g[i][x]);
    x=g[i][x]*f[n][i]+x;
  }

  fclose(stdin);
  fclose(stdout);
  return 0;
}
